﻿@model SchoolCommunicationSystem.Models.ListAdminModel
@{
    ViewBag.Title = "Tài khoản quản trị";
}
@Scripts.Render("~/bundles/tablesorter")
@Scripts.Render("~/bundles/tablesorterpaging")
<script type="text/javascript">
    $(function () {

        $("table")
            .tablesorter({
                widthFixed: true, widgets: ['zebra']
            })
            .tablesorterPager({ container: $("#pagersorter") });
    });
</script>
<div id="page-heading">
    <h1>Quản lý tài khoản</h1>
</div>
<div class="container">
    <div class="row">
        <div class="col-sm-12">
            <div class="panel panel-primary">
                <div class="panel-heading">
                    <h4>Quản lý tài khoản quản trị</h4>
                </div>
                <div class="panel-body">
                    <div class="module_contentwithsearch">
                        @using (Html.BeginForm("AdminAccount", "AccountManagement", FormMethod.Post, new { @class = "form-horizontal" }))
                        { 
                            <div class="form-group" style="margin-bottom: 0px;">
                                @Html.Label("Tên Đăng Nhập:", new { @class = "col-sm-2", @style = "width: 12%;" })
                                <div class="col-sm-2">
                                    @Html.TextBox("searchString")
                                </div>
                                <div class="col-sm-3">
                                    <button class="btn-primary btn searchbtn" type="submit" style="padding: 4px 15px; font-size: 13px; font-weight: 500;">Tìm kiếm</button>
                                </div>
                            </div>
                        }
                    </div>
                    <div class="module_contentresult">
                        <br />
                        <table class="tablesorter">
                            <thead>
                                <tr>
                                    <th>Mã quản trị viên</th>
                                    <th>Tên Đăng Nhập</th>
                                    <th>Email</th>
                                </tr>
                            </thead>
                            <tbody>
                                @foreach (var item in Model.AdminList)
                                {
                                    <tr>
                                        <td>@item.userID</td>
                                        <td>@item.userName</td>
                                        <td>@item.email</td>
                                    </tr>
                                }
                            </tbody>
                        </table>
                        <div id="pagersorter" class="pagersorter" style="clear: both;">
                            <form>
                                <img src="../../Content/images/first.png" class="first" />
                                <img src="../../Content/images/prev.png" class="prev" />
                                <input type="text" class="pagedisplay" />
                                <img src="../../Content/images/next.png" class="next" />
                                <img src="../../Content/images/last.png" class="last" />
                                <select class="pagesize">
                                    <option selected="selected" value="10">10</option>
                                    <option value="20">20</option>
                                    <option value="30">30</option>
                                    <option value="40">40</option>
                                </select>
                            </form>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
